<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <link rel="stylesheet" href="css/iconfont.css">
  <style>
    * {
      box-sizing: border-box;
      padding: 0;
      margin: 0;
    }

    li {
      list-style: none;
    }

    a {
      font-size: 12px;
      color: #686868;
      text-decoration: none;
    }

    body {
      display: flex;
      flex-direction: column;
      /*min-height: 100vh;可视区高度的100%*/
      min-height: 100vh;
    }

    header {
      width: 100%;
      background-color: red;
      height: 40px;
      display: flex;
      justify-content: center;
      align-items: center;
    }

    .main {
      flex: 1;
      color: #fff;
      display: flex;
    }

    .main-content {
      flex: 1;

      display: flex;
      justify-content: center;
      align-items: center;
      background-color: pink;
    }

    .main-sidebar {
      display: flex;
      width: 165px;
      order: -1;
      display: flex;
      justify-content: center;
      align-items: center;
      background-color: green;
    }

    .tabbar-container {
      height: 40px;
    }

    .tabbar {
      display: flex;
      flex-direction: row;
    }

    .tabbar-item {
      flex: 1;
    }

    .tabbar-link {
      display: flex;
      flex-direction: column;

      justify-content: center;
      align-items: center;
    }

    .tabbar-item-active .tabbar-link {
      color: #de181b;
    }
  </style>
</head>

<body>
  <header class="header">
    我是头部
  </header>
  <div class="main">
    <div class="main-content"></div>
    <div class="main-sidebar"></div>
  </div>
  <footer class="tabbar-container">
    <ul class="tabbar">
      <li class="tabbar-item">
        <a href="###" class="tabbar-link">
          <i class="iconfont icon-home"></i>
          <span>首页</span>
        </a>
      </li>
      <li class="tabbar-item tabbar-item-active">
        <a href="###" class="tabbar-link">
          <i class="iconfont icon-category"></i>
          <span>分类页</span>
        </a>
      </li>
      <li class="tabbar-item">
        <a href="###" class="tabbar-link">
          <i class="iconfont icon-cart"></i>
          <span>购物车</span>
        </a>
      </li>
      <li class="tabbar-item">
        <a href="###" class="tabbar-link">
          <i class="iconfont icon-personal"></i>
          <span>个人中心</span>
        </a>
      </li>
    </ul>
  </footer>
</body>

</html>